package com.googlecode.moneyManager.model;

import javax.persistence.Embedded;
import javax.persistence.Entity;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToOne;
import javax.persistence.PrimaryKeyJoinColumn;

/**
 * 
 * @author Sergiy Doroshenko
 * 
 */
@Entity
public class Branch extends BaseEntity{
    private Bank bank;

    private Address address;

    public Branch(){}
    
    public Bank getBank() {
	return bank;
    }
    
    @ManyToOne
    public void setBank(Bank bank) {
	this.bank = bank;
    }
    
    @Embedded
    public Address getAddress() {
	return address;
    }

    public void setAddress(Address address) {
	this.address = address;
    }

}
